FROM python:3.7-slim

MAINTAINER yangyuhang

WORKDIR /project

COPY requirements.txt /project

RUN sed -i 's#http://deb.debian.org#https://mirrors.aliyun.com#g' /etc/apt/sources.list && \
    sed -i 's#http://security.debian.org#https://mirrors.aliyun.com#g' /etc/apt/sources.list && \
    apt-get update && \
    apt-get install -y gcc && \
    pip install -r requirements.txt -i https://mirrors.aliyun.com/pypi/simple/ && \
    rm -rf /root/.cache && \
    apt-get --purge remove gcc -y

COPY . /project

ENTRYPOINT ["python","jms_sync.py"]
